/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package edu.fca.ui.tools;
import javax.swing.JOptionPane;

/**
 *
 * @author Romms
 */
public class AlertManager {
    public static void showAlert(String title, String message){
        JOptionPane.showMessageDialog(null, message, title,JOptionPane.ERROR_MESSAGE);
    }

    public static int showOkCancelAlert(String title, String message){
        int answer=JOptionPane.showOptionDialog(null, message, title, JOptionPane.YES_NO_OPTION,
                JOptionPane.QUESTION_MESSAGE, null,null,null);
                //yes=0 no=1 closed=-1
        return answer;
    }
}
